package com.yanqu.road.entity.config.vehicle;

import com.yanqu.road.entity.config.patrons.CombSkillUnlockInfo;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

/**
 * 组合珍兽
 */
public class VehicleComb {

	private int id;                //编号

	private int combSkillId;       //组合技能，获得时初始化，不可升级

	private int skillId = 0;           //技能编号，全部组合获得时解锁，解锁后可升级

	private Map<Integer,Integer> vehicleSkillMap = new ConcurrentHashMap<>();//当组合有多个组合技能时候使用

	private List<Integer> vehicleIdList = new ArrayList<>();  //组合中的编号

	private String extra = "";  //扩展参数，组合组合珍兽用到，两个组合id又组合一起，共同升级第一个技能

	private List<Integer> combList = new ArrayList<>();  //组合组合珍兽id解析

	//珍兽  技能  技能解锁条件
	private Map<Integer, Map<Integer, CombSkillUnlockInfo>> advancedSkillMap = new ConcurrentHashMap<>();

	private Map<Integer,List<Integer>> vehicleSelfSkillMap = new ConcurrentHashMap<>(); // 珍兽自身光环

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public int getCombSkillId() {
		return combSkillId;
	}

	public void setCombSkillId(int combSkillId) {
		this.combSkillId = combSkillId;
	}

	public int getSkillId(int vehicleId) {
		if(vehicleSkillMap.containsKey(vehicleId)){
			return vehicleSkillMap.get(vehicleId);
		}
		return skillId;
	}

	public Map<Integer, List<Integer>> getVehicleSelfSkillMap() {
		return vehicleSelfSkillMap;
	}

	public void setVehicleSelfSkillMap(Map<Integer, List<Integer>> vehicleSelfSkillMap) {
		this.vehicleSelfSkillMap = vehicleSelfSkillMap;
	}

	public void setVehicleSkill(Map<Integer, Integer> vehicleSkillMap) {
		this.vehicleSkillMap = vehicleSkillMap;
	}

	public void setSkillId(int skillId) {
		this.skillId = skillId;
	}

	public List<Integer> getVehicleIdList() {
		return vehicleIdList;
	}

	public void setVehicleIdList(List<Integer> vehicleIdList) {
		this.vehicleIdList = vehicleIdList;
	}

	public String getExtra() {
		return extra;
	}

	public void setExtra(String extra) {
		this.extra = extra;
	}

	public List<Integer> getCombList() {
		return combList;
	}

	public void setCombList(List<Integer> combList) {
		this.combList = combList;
	}

	public Map<Integer, Map<Integer, CombSkillUnlockInfo>> getAdvancedSkillMap() {
		return advancedSkillMap;
	}

	public void setAdvancedSkillMap(Map<Integer, Map<Integer, CombSkillUnlockInfo>> advancedSkillMap) {
		this.advancedSkillMap = advancedSkillMap;
	}
}
